package com.ly.ocw.entity;

import java.util.Date;

import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.builder.ToStringBuilder;

public class CrmMember {

	public CrmMember() {
	}

	private Long id; //
	private Date createDate; // 创建时间
	private Date updateDate; // 最后更新时间
	private Long deleted; // 是否删除（0：删，1：用）
	private String mobile; // 手机号
	private String membername; // 绑定会员卡是输入的姓名
	private String nickame; // 昵称
	private String email; //
	private String cardNumber; // 会员卡号
	private String memid; // 会员客户ID
	private String dateto; // 到期日期
	private String presentExperiencePoints; // 当前经验值
	private String relegationExperiencePoints; // 当前等级保级所需经验值
	private String promoteExperiencePointsNeed; // 当前等级升级所需经验值
	private String status; // 会员状态 100020 此会员正常；100002 此会员已否决；100003
							// 此会员已过期；100004 此会员已暂停

	private String pointsBalance; // 会员积分余额
	private String tierLevel; // 会员等级 ZA:银卡、ZB:金卡、ZC:铂金卡
	private String openid; //
	private String cardid; //

	public String getMembername() {
		return membername;
	}

	public void setMembername(String membername) {
		this.membername = membername;
	}

	public boolean getHasNextLevel() {
		boolean hasNextLevel = false;
		if (StringUtils.isNotBlank(this.tierLevel)) {
			this.tierLevel = this.tierLevel.trim();
			if ("ZA".equalsIgnoreCase(this.tierLevel)) {
				hasNextLevel = true;
			} else if ("ZB".equalsIgnoreCase(this.tierLevel)) {
				hasNextLevel = true;
			}
		}
		return hasNextLevel;
	}

	public String getNextLevelName() {
		String nextLevelName = "银卡";
		if (StringUtils.isNotBlank(this.tierLevel)) {
			this.tierLevel = this.tierLevel.trim();
			if ("ZA".equalsIgnoreCase(this.tierLevel)) {
				nextLevelName = "金卡";
			} else if ("ZB".equalsIgnoreCase(this.tierLevel)) {
				nextLevelName = "铂金卡";
			}
		}
		return nextLevelName;
	}

	public String getLevelName() {
		String levelName = "银卡";
		if (StringUtils.isNotBlank(this.tierLevel)) {
			this.tierLevel = this.tierLevel.trim();
			if ("ZA".equalsIgnoreCase(this.tierLevel)) {
				levelName = "银卡";
			} else if ("ZB".equalsIgnoreCase(this.tierLevel)) {
				levelName = "金卡";
			} else if ("ZC".equalsIgnoreCase(this.tierLevel)) {
				levelName = "铂金卡";
			}
		}
		return levelName;
	}

	public String getCardid() {
		return cardid;
	}

	public void setCardid(String cardid) {
		this.cardid = cardid;
	}

	public String getOpenid() {
		return openid;
	}

	public void setOpenid(String openid) {
		this.openid = openid;
	}

	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public String getCardNumber() {
		return cardNumber;
	}

	public void setCardNumber(String cardNumber) {
		this.cardNumber = cardNumber;
	}

	/**
     *
     **/
	public Long getId() {
		return id;
	}

	/**
	 *
	 **/
	public void setId(Long id) {
		this.id = id;
	}

	/**
	 * 创建时间
	 **/
	public Date getCreateDate() {
		return createDate;
	}

	/**
	 * 创建时间
	 **/
	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

	/**
	 * 最后更新时间
	 **/
	public Date getUpdateDate() {
		return updateDate;
	}

	/**
	 * 最后更新时间
	 **/
	public void setUpdateDate(Date updateDate) {
		this.updateDate = updateDate;
	}

	/**
	 * 是否删除（0：删，1：用）
	 **/
	public Long getDeleted() {
		return deleted;
	}

	/**
	 * 是否删除（0：删，1：用）
	 **/
	public void setDeleted(Long deleted) {
		this.deleted = deleted;
	}

	/**
	 * 手机号
	 **/
	public String getMobile() {
		return mobile;
	}

	/**
	 * 手机号
	 **/
	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	/**
     *
     **/
	public String getEmail() {
		return email;
	}

	/**
	 *
	 **/
	public void setEmail(String email) {
		this.email = email;
	}

	/**
	 * 昵称
	 **/
	public String getNickame() {
		return nickame;
	}

	/**
	 * 昵称
	 **/
	public void setNickame(String nickame) {
		this.nickame = nickame;
	}

	/**
	 * 会员客户ID
	 **/
	public String getMemid() {
		return memid;
	}

	/**
	 * 会员客户ID
	 **/
	public void setMemid(String memid) {
		this.memid = memid;
	}

	/**
	 * 到期日期
	 **/
	public String getDateto() {
		return dateto;
	}

	/**
	 * 到期日期
	 **/
	public void setDateto(String dateto) {
		this.dateto = dateto;
	}

	/**
	 * 当前经验值
	 **/
	public String getPresentExperiencePoints() {
		return presentExperiencePoints;
	}

	/**
	 * 当前经验值
	 **/
	public void setPresentExperiencePoints(String presentExperiencePoints) {
		this.presentExperiencePoints = presentExperiencePoints;
	}

	/**
	 * 当前等级保级所需经验值
	 **/
	public String getRelegationExperiencePoints() {
		return relegationExperiencePoints;
	}

	/**
	 * 当前等级保级所需经验值
	 **/
	public void setRelegationExperiencePoints(String relegationExperiencePoints) {
		this.relegationExperiencePoints = relegationExperiencePoints;
	}

	/**
	 * 当前等级升级所需经验值
	 **/
	public String getPromoteExperiencePointsNeed() {
		return promoteExperiencePointsNeed;
	}

	/**
	 * 当前等级升级所需经验值
	 **/
	public void setPromoteExperiencePointsNeed(String promoteExperiencePointsNeed) {
		this.promoteExperiencePointsNeed = promoteExperiencePointsNeed;
	}

	/**
	 * 会员积分余额
	 **/
	public String getPointsBalance() {
		return pointsBalance;
	}

	/**
	 * 会员积分余额
	 **/
	public void setPointsBalance(String pointsBalance) {
		this.pointsBalance = pointsBalance;
	}

	/**
	 * 会员等级 ZA:银卡、ZB:金卡、ZC:铂金卡
	 **/
	public String getTierLevel() {
		return tierLevel;
	}

	/**
	 * 会员等级 ZA:银卡、ZB:金卡、ZC:铂金卡
	 **/
	public void setTierLevel(String tierLevel) {
		this.tierLevel = tierLevel;
	}

	@Override
	public String toString() {
		return ToStringBuilder.reflectionToString(this);
	}
}